<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>

    </style>
</head>

<body>
    <div id="app">       
        <h1>热卖书籍</h1>
        <ul>
            <li v-if="item.isHot==true" v-for="(item,index) in bookobjs" >
                <p>书号：{{item.id}}</p>
                <p>书名：{{item.name}}</p>
                <p>是否热卖：{{item.isHot?"是":"否"}}</p>
            </li>
        </ul>
    </div>
</body>

</html>
<script src="./js/vue2.js"></script>
<script>

    let vm = new Vue({
        el: "#app",
        data: {
            bookobjs:[
                {
                    "id":"01001",
                    "name":"大学",
                    "isHot":true
                },
                {
                    "id":"01002",
                    "name":"中庸",
                    "isHot":false
                },
                {
                    "id":"01003",
                    "name":"孟子",
                    "isHot":true
                }
            ]
        }
    });


</script>